//
//  Extension+UIImageView.swift
//  SHWeibo01
//
//  Created by 卫平玉 on 16/7/22.
//  Copyright © 2016年 卫平玉. All rights reserved.
//

import UIKit
import SDWebImage
extension UIImageView {
    
    convenience init(imgName: String) {
        self.init(image:UIImage(named: imgName))
    }
    
    // 对SDWebImage 封装
    func sh_setImage(urlString: String?, placeholderImgName: String){
        
        self.sd_setImageWithURL(NSURL(string: urlString ?? ""), placeholderImage: UIImage(named: placeholderImgName))
  }
}
